package org.lex.ftp.ui.logging;

import java.awt.Color;

import org.lex.net.log.Log.Type;


public class ColorConstants {
	private ColorConstants() {
	}

	public static final Color SEND_FG = new Color(0, 0, 139);
	public static final Color SEND_BG = new Color(175, 238, 238);
	public static final Color REPLY_FG = new Color(0, 139, 0);
	public static final Color REPLY_BG = new Color(152, 251, 152);
	public static final Color ERROR_FG = new Color(139, 0, 0);
	public static final Color ERROR_BG = new Color(255, 192, 203);
	public static final Color MISC_FG = new Color(0, 0, 0);
	public static final Color MISC_BG = new Color(220, 255, 255);

	public static Color getBackground(Type type) {
		switch (type) {
		case SEND:
			return SEND_BG;
		case REPLY:
			return REPLY_BG;
		case ERROR:
			return ERROR_BG;
		case MISC:
			return MISC_BG;
		default:
			return Color.BLACK;
		}
	}

	public static Color getForeground(Type type) {
		switch (type) {
		case SEND:
			return SEND_FG;
		case REPLY:
			return REPLY_FG;
		case ERROR:
			return ERROR_FG;
		case MISC:
			return MISC_FG;
		default:
			return Color.WHITE;
		}
	}
}
